<template>
    <div class="container">
        <h3 class="el-icon-s-data" style="margin-bottom: 2rem"> 发现</h3>
        <Selector :data="[{nickname: '全部', id: '0'},{nickname: '查询', id: '1'},...$store.state.user.name]"/>
    </div>
</template>

<script>
    import Selector from "../components/Home/Selector";
    export default {
        name: "Home",
        async created() {
            if(this.$store.state.user.isLogin){
                await this.$store.dispatch("user/listNick");
            }
        },
        components: {Selector},
    }
</script>

<style scoped>
    .container{
        background-color: #ffffff;
        padding: 3rem;
    }
</style>